package edu.tgc.entity.file;

import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.ManyToOne;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import javax.persistence.Transient;

import org.springframework.format.annotation.DateTimeFormat;

import edu.tgc.entity.file.dictionary.TbDataType;
import edu.tgc.entity.system.BaseEntity;
import edu.tgc.entity.system.SysUser;
@Entity
public class TbData extends BaseEntity{
	@Transient
	private static String path="d:/bzzy/data";
	private String filename;
	private TbDataType dataType;
	private String comment;
	private Date createTime;
	private SysUser user;
	
	
	public static String getPath() {
		return path;
	}
	public static void setPath(String path) {
		TbData.path = path;
	}
	public String getFilename() {
		return filename;
	}
	public void setFilename(String filename) {
		this.filename = filename;
	}
	@ManyToOne
	public TbDataType getDataType() {
		return dataType;
	}
	public void setDataType(TbDataType dataType) {
		this.dataType = dataType;
	}
	public String getComment() {
		return comment;
	}
	public void setComment(String comment) {
		this.comment = comment;
	}
	
	@Temporal(value=TemporalType.TIMESTAMP)
	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
	public Date getCreateTime() {
		return createTime;
	}
	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}
	
	@ManyToOne
	public SysUser getUser() {
		return user;
	}
	public void setUser(SysUser user) {
		this.user = user;
	}
	
	
	
}
